package com.yyj.controller;

import com.github.pagehelper.PageInfo;
import com.yyj.entity.*;
import com.yyj.service.PutService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

import java.util.List;

/*跨域*/
@CrossOrigin
@RestController
@RequestMapping("/pet")
public class PutController {
    @Autowired
    PutService putService;


    @GetMapping("/{originalOwnerId}")
    public Result getMyPut(@PathVariable Integer originalOwnerId) {
        List<Pet> myPut = putService.getMyPut(originalOwnerId);
        return Result.success(myPut);
    }

}